package com.project.service.impl;

import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.project.bean.LogUserBean;
import com.project.mapper.LogMapper;
import com.project.service.ILogService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.time.LocalDate;
@Service
public class LogServiceImpl implements ILogService {
    @Autowired
    private LogMapper logMapper;
    @Override
    public void findAll() {

    }

    @Override
    public PageInfo<LogUserBean> findByItem(int pageNO, LocalDate start, LocalDate end) {
        PageHelper.startPage(pageNO,ILogService.PAGESIZE);
        PageInfo<LogUserBean> pageInfo = PageInfo.of(logMapper.findByItem(start,end));
        return pageInfo;
    }
}
